-- GENERATED SPELL FOR [Oasis Snapjaw] --


function spell0_3461(pUnit, Event) --@Bite,n/a--
pUnit:FullCastSpellOnTarget(17255,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_3461', 547, 1)
end

function spell1_3461(pUnit, Event) --@Bite,n/a--
pUnit:FullCastSpellOnTarget(17256,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_3461', 624, 1)
end

function spell2_3461(pUnit, Event) --@Cower,n/a--
pUnit:FullCastSpellOnTarget(1753,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_3461', 0, 1)
end

function spell3_3461(pUnit, Event) --@Growl,n/a--
pUnit:FullCastSpellOnTarget(14916,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_3461', 0, 1)
end

function spell4_3461(pUnit, Event) --@Sling Dirt,n/a--
pUnit:FullCastSpellOnTarget(6530,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_3461', 11000, 1)
end

function Sorts_3461(pUnit, Event)
local choix_sorts_3461 = math.random(0, 4)
if choix_sorts_3461 == 0 then
pUnit:RegisterEvent('spell0_3461', 1, 1)
end
if choix_sorts_3461 == 1 then
pUnit:RegisterEvent('spell1_3461', 1, 1)
end
if choix_sorts_3461 == 2 then
pUnit:RegisterEvent('spell2_3461', 1, 1)
end
if choix_sorts_3461 == 3 then
pUnit:RegisterEvent('spell3_3461', 1, 1)
end
if choix_sorts_3461 == 4 then
pUnit:RegisterEvent('spell4_3461', 1, 1)
end
end

function mob3461_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_3461', math.random(1500, 3000), 1)
end

function mob3461_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob3461_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob3461_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(3461, 1, 'mob3461_Action')
RegisterUnitEvent(3461, 2, 'mob3461_Leave')
RegisterUnitEvent(3461, 3, 'mob3461_Kill')
RegisterUnitEvent(3461, 4, 'mob3461_Die')
